package com.woniuxy.riskmanage.service.impl;

import com.woniuxy.commons.entity.RiskRules;
import com.woniuxy.riskmanage.mapper.RiskManageMapper;
import com.woniuxy.riskmanage.service.RuleService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * @author author
 * @create 2021-11-22 12:01
 */
@Service
public class RuleServiceImpl implements RuleService {
    @Resource
    private RiskManageMapper riskManageMapper;
    @Override
    public List<RiskRules> selectAllRules(RiskRules riskRules, Integer pageIndex, Integer pageSize) {
        return riskManageMapper.selectAllRules(riskRules, pageIndex, pageSize);
    }

    @Override
    public int selectRulesCountBylimit(RiskRules riskRules) {
        return riskManageMapper.selectRulesCountBylimit(riskRules);
    }

    @Override
    public void addRule(RiskRules rules) {
        riskManageMapper.addRule(rules);
    }
}
